package com.simplemonkey.tooltip;

import com.simplemonkey.IWidget;

/**
 * A tooltip widget is just a widget that can handle a request to display certain information
 * The widget will determine when and how to respond to that request.
 * 
 * @author Sam
 *
 */
public interface IToolTip {
	/**
	 * Show the given message for this widget.
	 * @param owner
	 * @param toolTip
	 * @param x The x coordinate to show the tooltip at, in world coordinates (this is only a hint; the tooltip does not need to respect this)
	 * @param y The y coordinate to show the tooltip at, in world coordinates (this is only a hint; the tooltip does not need to respect this)
	 */
	public void showToolTip(IWidget owner, String toolTip, float x, float y);
	
	/**
	 * If the current tooltip belongs to this owner, then signal that it should be hidden.
	 * (Does nothing if the given owner's tooltip is now being displayed).
	 * @param owner
	 */
	public void hideToolTip(IWidget owner);
}
